<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="Admin/webroot/css/style.css"/>
<title>添加产品</title>
</head>
<script type="text/javascript" src="Admin/webroot/js/jquery-1.7.2.min.js"></script>
<script type="text/javascript" src="Admin/webroot/js/global.js"></script>
<script type="text/javascript" src="Admin/webroot/js/input.js"></script>
<body >
<!--[if lte IE 6]>
<script src="js/DD_belatedPNG_0.0.8a.js" language="javascript" type="text/javascript"></script>
<script type="text/javascript">
	DD_belatedPNG.fix('.pngfix');
</script>
<![endif]-->
<div class="rightbox">
    	<div class="rightbox-col" id="rightbox">
        	<div class="main">
                <div class="title">
                   
                   当前位置<a href="#">>首页</a>><a href="#">内容管理</a>>单页内容
                </div>
                <div class="bd">
                	<div class="height_20"></div>
                    <div class="add-pro-info">
                       
                            <div class="pro-info">
                            	<div id="pro">
                                    <div class="left-table"><span class="red">*</span>标题：</div>
                                    <div class="right-table"><input type="text" name="title" value="{$art.title}"/></div>
                                    <div class="msg"></div>
                                    <div class="height_10"></div>
                                    {if $_CFG.DIGLOSSIA==1}
                                    <div class="left-table"><span class="red">*</span>英文标题：</div>
                                    <div class="right-table"><input type="text" name="en_title" value="{$art.en_title}" placeholder="请输入标题"/></div>
                                    <div class="msg"></div>
                                    <div class="height_10"></div>
                                    {/if}
                                </div>
                            </div>
                            <div class="height_20"></div>
                            <div class="pro">
                            	<div class="hd next-hd">
                                	<span class="focus"></span>
                                    扩展信息
                                    <div class="clear"></div>
                                </div>
                                <div class="bd" style="display:block">
                                	<table cellpadding="0" cellspacing="0" border="0" width="100%">
                                    <tr>
                                        <td width="85px" style="padding-right:7px" align="right">页面标题</td>
                                        <td width="434px"><input type="text" name="page_title" value="{$art.page_title}"/></td>
                                        <td></td>
                                    </tr>
                                    <tr>
                                        <td width="85px" style="padding-right:7px" align="right">页面关键词：</td>
                                        <td width="434px"><textarea class="keywords" name="keywords">{$art.keywords}</textarea></td>
                                        <td valign="top"></td>
                                    </tr>
                                    <tr>
                                        <td width="85px" style="padding-right:7px" align="right">页面摘要：</td>
                                        <td width="434px"><textarea class="keywords" name="abstract">{$art.abstract}</textarea></td>
                                        <td></td>
                                    </tr>
                                    <tr>
                                        <td width="85px" style="padding-right:7px" align="right">缩略图</td>
                                        <td width="434px"><input type="text" id="img_url" disabled="disabled" name="thumb_url" value="{$art.thumb}" id="thumb"/></td>
                                        <td>
                                        	<a href="javascript:;"   class="localUpload" onclick="$(this).next().children('form').children('.ke-upload-file').click()">本地上传</a>
                    <input id="uploadButton_" return_url="img_url" type="button" value="submit" />     
                                           
                                        </td>
                                    </tr>
                                </table>
                                </div>
                            </div>
                            <div class="height_20"></div>
                            
                            <div class="height_20"></div>
                            <div class="pro">
                            	<div class="hd next-hd">
                                	<span class="icon-c" ></span>
                                    文章正文
                                     <div class="clear"></div>
                                </div>
                                <div class="bd">
                                	<textarea class="pro-view" id="pro-view" name="content" style="width:680px; height:348px;">{$art.content}</textarea>
                                </div>
                            </div>
                            <div class="height_20"></div>
                            {if $_CFG.DIGLOSSIA==1}
                            <div class="pro">
                            	<div class="hd next-hd">
                                	<span class="icon-c" ></span>
                                    英文正文
                                     <div class="clear"></div>
                                </div>
                                <div class="bd">
                                	<textarea name="en_content" class="pro-view" id="pro-view" style="width:680px; height:348px;">{$art.en_content}</textarea>
                                </div>
                            </div>
                            <div class="height_20"></div>
                            {/if}
                            <input type="hidden" name="cat_id" value="{$cat_id}" />
                            <input type="hidden" name="id" value="{$id}" />
                          <input type="button" class="pro-add-sub submit_btn"  value="保存"/>
                            <div class="height_24"></div>
                       
                    </div>
                </div>
            </div>
        </div>
         
        <div class="clear"></div>
    </div>
<script type="text/javascript" src="Admin/webroot/js/editor/kindeditor.js"></script>
<script type="text/javascript" src="Admin/webroot/js/kindeditor_upload.js"></script>
<script type="text/javascript">
    $(function(){
		hungry_uploadimg('index.php?g=admin&m=page&a=file');
		$('.pro-add-sub').click(function(){
			var action = '{$action}';
			var cat_id=($('input[name=cat_id]').val());
			var id=($('input[name=id]').val());
			var title=($('input[name=title]').val());
			var abstract=($('textarea[name=abstract]').val());
			var keywords=($('textarea[name=keywords]').val());
			var en_title=($('input[name=en_title]').val());
			var en_content=$('textarea[name=en_content]').val();
			var content=$('textarea[name=content]').val();
			
			var created=($('input[name=created]').val());
			var page_title=($('input[name=page_title]').val());
			var thumb=($('input[name=thumb_url]').val());
			$.post('index.php?g=admin&m=page&a='+action,{ id:id,content:content,cat_id:cat_id,title:title,abstract:abstract,created:created,keywords:keywords,page_title:page_title,thumb:thumb,en_title:en_title,en_content:en_content},function(result){
				
			showMsg(result.content,result.url);
		
				},'json');
			})
		
		});
	
</script>
<script type="text/javascript">
$(".next-hd").click(function(){
	var html=$(this).find("span").attr("class");
	if(html=='icon-c'){
		$(this).next(".bd").show();
		$(this).find("span").attr('class','focus');
		
	}else{
		$(this).next(".bd").hide();
		$(this).find("span").attr('class','icon-c');
	}
})


</script>
</body>
</html>
